package com.ilxqx.framework.system.controller.hook.holder;

import com.ilxqx.framework.system.controller.hook.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * 钩子支持有类
 * @author venus
 */
@Component
public class HookHolder {

	public static List<PreAdd> preAdds;
	public static List<PreModify> preModifies;
	public static List<PreDelete> preDeletes;
	public static List<PostAdd> postAdds;
	public static List<PostModify> postModifies;
	public static List<PostDelete> postDeletes;

	@Autowired
	public HookHolder(
		List<PreAdd> preAdds,
		List<PreModify> preModifies,
		List<PreDelete> preDeletes,
		List<PostAdd> postAdds,
		List<PostModify> postModifies,
		List<PostDelete> postDeletes) {
		HookHolder.preAdds = preAdds;
		HookHolder.preModifies = preModifies;
		HookHolder.preDeletes = preDeletes;
		HookHolder.postAdds = postAdds;
		HookHolder.postModifies = postModifies;
		HookHolder.postDeletes = postDeletes;
	}

}
